#ifndef __GfxDriver_WGL_WGLDepthBuffer_h__
#define __GfxDriver_WGL_WGLDepthBuffer_h__

#include "GfxDriver/DepthBuffer.h"

#include "GfxDriver/WGL/GLInclude.h"

namespace Orca {
	
	class GfxDriver;

	//--------------------------------------------------------------------------
	class WGLDepthBuffer : public DepthBuffer {

	public:
		static WGLDepthBuffer* create(
			 GfxDriver *gfxDriver
			,uint32 width
			,uint32 height
			,uint32 depthBits
			,uint32 stencilBits);

		WGLDepthBuffer();
		virtual ~WGLDepthBuffer();

		virtual uint32 getWidth();
		virtual uint32 getHeight();
		virtual unsigned int getAPIHandle();

	private:
		GfxDriver *mGfxDriver;
		uint32 mW, mH;
		GLuint mGLHandle;

		bool _init(
			 GfxDriver *gfxDriver
			,uint32 width
			,uint32 height
			,uint32 depthBits
			,uint32 stencilBits);
	};

}

#endif	// __GfxDriver_WGL_WGLDepthBuffer_h__